package cn.edu.zut.cs.Business;

import cn.edu.zut.cs.Dao.CheckapplyMapper;
import cn.edu.zut.cs.Model.Checkapply;
import cn.edu.zut.cs.Model.User;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class CheckapplyServiceImpl implements CheckapplyService {
    @Autowired
    CheckapplyMapper checkapplyMapper;

    public void setCheckapplyMapper(CheckapplyMapper checkapplyMapper) {
        this.checkapplyMapper = checkapplyMapper;
    }

    @Override
    public int addfirendcheck(String requestper, String reponsedper) {
        return checkapplyMapper.addfirendcheck(requestper,reponsedper);
    }

    @Override
    public List<User> queryByreponsedper(String reponsedper) {
        return checkapplyMapper.queryByreponsedper(reponsedper);
    }

    @Override
    public List<Checkapply> query(String reponsedper) {
        return checkapplyMapper.query(reponsedper);
    }

    @Override
    public int updateanwserper(String requestper, String reponsedper, String answerper) {
        return checkapplyMapper.updateanwserper(requestper,reponsedper,answerper);
    }


}
